﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Web.UI.WebControls;
using System.Collections;
using System.Web;
namespace OneShoppingUtility
{
    public class UtilityMD5
    {
        /// <summary>
        /// 用MD5哈希算法加密字符串
        /// </summary>
        /// <param name="str">要加密的字符串</param>
        /// <returns>加密后的字符串</returns>
        public static string MD5Encrypt(string str)
        {

            return System.Web.Security.FormsAuthentication.
                HashPasswordForStoringInConfigFile(str, "MD5").ToLower();
        }

       

    }
}
